package com.home766.service.impl;

import com.home766.dao.OrderRewardDao;
import com.home766.entity.OrderReward;
import com.home766.service.OrderRewardService;
import net.biz.entity.Brand;
import net.biz.service.impl.BaseServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

/**
 * 门店下单奖励提成点-service
 */
@Service("orderRewardServiceImpl")
public class OrderRewardServiceImpl extends BaseServiceImpl<OrderReward, Long> implements OrderRewardService{
	
	@Resource(name="orderRewardDaoImpl")
	public void setBaseDao(OrderRewardDao orderRewardDao) {
		super.setBaseDao(orderRewardDao);
	}
	
	@Resource(name="orderRewardDaoImpl")
	private OrderRewardDao orderRewardDao;
	
	/**
	 * 根据类型和分类品牌查询
	 * @param type     类型
	 * @param category 分类
	 * @param brand    品牌
	 * @return
	 */
	@Override
	public OrderReward findByTypeAndCategory(Integer type, Long category, Brand brand) {
		return orderRewardDao.findByTypeAndCategory(type,category,brand);
	}
	
}
